home *** CD-ROM | disk | FTP | other *** search
- on resetReg theStartSprite,theEndSprite
- -- this handler is used to reset the registration point of a cast based on where it's
- -- locH-locV are as it resides in a sprite in relationship to a locH of 320 and a locV of 240.
- -- theSprite - the sprite number where the cast to be changed resides in.
- if voidP(theEndSprite) then
- set theSprite = theStartSprite
- set tempList = []
- set tempList = locList(theSprite)
- set tempList = [320,240] - tempList
- set theCast = the castNum of sprite theSprite
- set thePoint = the regPoint of cast theCast
- set the regPoint of cast theCast = (thePoint + point(getAt(tempList,1),getAt(tempList,2)))
- else
- repeat with theSprite = theStartSprite to theEndSprite
- set tempList = []
- set tempList = locList(theSprite)
- set tempList = [320,240] - tempList
- set theCast = the castNum of sprite theSprite
- set thePoint = the regPoint of cast theCast
- set the regPoint of cast theCast = (thePoint + point(getAt(tempList,1),getAt(tempList,2)))
- end repeat
- end if
- end